#!/usr/bin/env bash

####
# usge:
#       bash modify_product_config_file_name.sh dev_service.conf
# 参数是对应环境的配置文件名


APP_HOME=`cd $(dirname $0)/..;pwd`
MODIFY_SERVICE_FILE=$1
SERVICE_FILE="service.conf"
CONFIG_PATH="${APP_HOME}/config"

cd ${CONFIG_PATH}

#判断对应的文件是否存在
if [ ! -f "${MODIFY_SERVICE_FILE}" ];then
    exit 0
fi

# 配置文件替换
cp ${MODIFY_SERVICE_FILE} ${SERVICE_FILE}



